import myaxios from "../MyAxios";
import BASEURL from "../BaseUrl";

const TCHYURL = BASEURL.TCHYURL;
const basicSettingApi = {
  // 账号管理
  getUserList(params) {
    let url = TCHYURL + "/system/user/getSysList";
    return myaxios.post(url, params);
  },
  // 银行名称信息
  getBankNameList(params) {
    let url = TCHYURL + "/order/bank/queryBank";
    return myaxios.get(url, params);
  },
  getStaffList(params) {
    let url = TCHYURL + "/system/user/getSysStaffList";
    return myaxios.get(url, params);
  },
  // 修改用户状态
  updateUserStatus(params) {
    let url = TCHYURL + "/system/user/updateUserStatusByUserId";
    return myaxios.get(url, params);
  },
  //新增账号
  addAccount(params) {
    let url = TCHYURL + "/system/user/addSysUser";
    return myaxios.post(url, params);
  },
  // 账号验重
  checkUserName(params) {
    let url = TCHYURL + "/system/user/checkUserName";
    return myaxios.get(url, params);
  },
  //编辑账号信息
  updataAccount(params) {
    let url = TCHYURL + "/system/user/updateSysUser";
    return myaxios.post(url, params);
  },
  //修改密码
  updatePassword(params) {
    let url = TCHYURL + "/system/user/updatePassword";
    return myaxios.post(url, params);
  },
  resetPassword(params) {
    let url = TCHYURL + "/system/user/resetPassword";
    return myaxios.get(url, params);
  },
  removeUser(params) {
    let url = TCHYURL + "/system/user/remove";
    return myaxios.Delete(url, params);
  },

  //获取角色
  getRoles(params) {
    let url = TCHYURL + "/system/role/optionselect";
    return myaxios.get(url, params);
  },
  //获取部门
  getDepartment(params) {
    let url = TCHYURL + "/system/dept/list";
    return myaxios.get(url, params);
  },
  //角色列表
  getRoleList(params) {
    let url = TCHYURL + "/system/role/list";
    return myaxios.get(url, params);
  },
  //所有角色选项
  getRoleSelection(params) {
    let url = TCHYURL + "/system/role/getRoleDown";
    return myaxios.get(url, params);
  },
  //删除角色
  DeleteRole(params) {
    console.log("接口拼接", params.roleIds);
    let url = TCHYURL + "/system/role/" + params.roleIds;
    return myaxios.Delete(url);
  },
  //新增角色
  addRole(params) {
    let url = TCHYURL + "/system/role/add";
    return myaxios.put(url, params);
  },
  //编辑角色
  editRole(params) {
    let url = TCHYURL + "/system/role/edit";
    return myaxios.post(url, params);
  },
  // 编辑回填
  getEditRoleData(params) {
    let url = TCHYURL + "/system/role/" + params.roleId;
    return myaxios.get(url);
  },
  //编辑 回填菜单权限
  getEditRoleMenu(params) {
    let url =
      TCHYURL +
      "/system/menu/roleMenuTreeselect/" +
      params.roleId +
      "/" +
      params.useType;
    return myaxios.get(url);
  },

  //权限选项
  getAuthorityOption(params) {
    let url = TCHYURL + "/system/menu/treeselect";
    return myaxios.get(url, params);
  },
  // 车型配置 列表
  getVehicleModelCategoryList(params) {
    let url =
      TCHYURL + "/account/vehicleModelCategory/vehicleModelCategoryList";
    return myaxios.get(url, params);
  },
  //车型配置  新增
  vehicleConfigAdd(params) {
    let url = TCHYURL + "/account/vehicleModelCategory/addVehicleModel";
    return myaxios.post(url, params);
  },
  //车型配置 详情
  vehicleConfigDetail(params) {
    let url = TCHYURL + "/account/vehicleModelCategory/detailVehicleModel";
    return myaxios.get(url, params);
  },
  //车型配置 编辑
  vehicleConfigEdit(params) {
    let url = TCHYURL + "/account/vehicleModelCategory/editVehicleModel";
    return myaxios.post(url, params);
  },
  //  平台端/车辆类型/车型能源车厢数据
  vehicleEnergyData(params) {
    let url = TCHYURL + "/account/vehicleModelCategory/getCategoryLabel";
    return myaxios.post(url, params);
  },

  //  平台端/客服管理/新增客服回话
  addCustomerService(params) {
    let url = TCHYURL + "/system/menu/addCustomerService";
    return myaxios.post(url, params);
  },
  //  平台端/客服管理/客服查询
  queryCustomerService(params) {
    let url = TCHYURL + "/system/menu/queryCustomerService";
    return myaxios.get(url, params);
  },
  //  平台端/客服管理/客服删除
  removeCustomerService(params) {
    let url = TCHYURL + "/system/menu/removeCustomerService";
    return myaxios.post(url, params);
  },
  //  平台端/客服管理/客服查询详情
  echoCustomerService(params) {
    let url = TCHYURL + "/system/menu/echoCustomerService";
    return myaxios.get(url, params);
  },
  //  平台端/客服管理/客服查询修改
  modifyCustomerService(params) {
    let url = TCHYURL + "/system/menu/modifyCustomerService";
    return myaxios.post(url, params);
  },
  //车型名称
  checkCategoryName(params) {
    let url = TCHYURL + "/account/vehicleModelCategory/checkCategoryName";
    return myaxios.get(url, params);
  },
  //删除车型
  removeVehicleModel(params) {
    let url =
      TCHYURL + "/account/vehicleModelCategory/removeVehicleModel/" + params;
    return myaxios.Delete(url);
  },
  // 账户创建与绑定审核
  behaviorStatement(params) {
    let url = TCHYURL + "/order/order/behaviorStatement";
    return myaxios.Delete(url, params);
  },
  //资金流水
  queryPageWalletIndex(params) {
    let url = TCHYURL + "/account/driver/queryPageWalletIndex";
    return myaxios.post(url, params);
  },
  //会员开户
  memberOpenAnAccount(params) {
    let url = TCHYURL + "/order/bank/memberOpenAnAccount";
    return myaxios.post(url, params);
  },
  //会员开户信息
  queryMemberOpenAnAccount(params) {
    let url = TCHYURL + "/order/bank/queryMemberOpenAnAccount";
    return myaxios.post(url, params);
  },
  //会员绑卡
  addBindingCard(params) {
    let url = TCHYURL + "/order/bank/addBindingCard";
    return myaxios.post(url, params);
  },
  //会员绑卡信息
  queryBindingCard(params) {
    let url = TCHYURL + "/order/bank/queryBindingCard";
    return myaxios.post(url, params);
  },

  //添加凌晨服务费
  addBillingRulesBefore(params) {
    let url = TCHYURL + "/order/bill/addBillingRulesBefore";
    return myaxios.post(url, params);
  },
  //获取已选择过的城市城区
  getSelectedCity(params) {
    let url = TCHYURL + "/order/bill/echoAddress";
    return myaxios.get(url, params);
  },
  //推广中心列表
  queryDriverCode(params) {
    let url = TCHYURL + "/account/driver/queryDriverCode";
    return myaxios.post(url, params);
  },
  //推广中心 修改结算 状态
  modifyDriverCode(params) {
    let url = TCHYURL + "/account/driver/modifyDriverCode";
    return myaxios.post(url, params);
  },
  // 会员等级列表
  membershipLevelsList(params) {
    let url = TCHYURL + "/account/platformSetup/list";
    return myaxios.get(url, params);
  },
  //修改会员等级数据
  updateMembershipLevel(params) {
    let url = TCHYURL + "/account/platformSetup/add";
    return myaxios.post(url, params);
  },
  //自动评价时间修改
  updateAutoEvaluation(params) {
    let url = TCHYURL + "/account/platformSetup/edit";
    return myaxios.post(url, params);
  },
  // 当前自动评价时间
  getAutoEvaluation(params) {
    let url = TCHYURL + "/account/platformSetup/getInfoAtPresent/2";
    return myaxios.get(url, params);
  },
  //提现时间修改
  updateWithdrawTime(params) {
    let url = TCHYURL + "/account/platformSetup/edit";
    return myaxios.post(url, params);
  },
  // 获取当前提现时间
  getWithdrawTime(params) {
    let url = TCHYURL + "/account/platformSetup/getInfoAtPresent/1";
    return myaxios.get(url, params);
  },
  //保险咨询管理
  queryPageDriverInsure(params) {
    let url = TCHYURL + "/account/driver/queryPageDriverInsure";
    return myaxios.post(url, params);
  },
  //保险咨询管理
  modifyDriverInsureByDid(params) {
    let url = TCHYURL + "/account/driver/modifyDriverInsureByDid";
    return myaxios.post(url, params);
  },
  //保险咨询管理
  deleteDriverInsureByDid(params) {
    let url = TCHYURL + "/account/driver/deleteDriverInsureByDid";
    return myaxios.post(url, params);
  },
  //未提现
  queryNotWithdrawal(params) {
    let url = TCHYURL + "/order/bank/queryNotWithdrawal";
    return myaxios.post(url, params);
  },
  //未提现汇总
  queryNotWithdrawalSummary(params) {
    let url = TCHYURL + "/order/bank/queryNotWithdrawalSummary";
    return myaxios.post(url, params);
  },
  //未提现导出
  queryExportNotWithdrawal(params) {
    let url = TCHYURL + "/order/bank/queryExportNotWithdrawal";
    return myaxios.post(url, params);
  },
  //货物统计
  queryGoodsStatistics(params) {
    let url = TCHYURL + "/order/bank/queryGoodsStatistics";
    return myaxios.post(url, params);
  },
  //货物统计
  queryExportGoodsStatistics(params) {
    let url = TCHYURL + "/order/bank/queryExportGoodsStatistics";
    return myaxios.post(url, params);
  },
  //费用统计
  queryCostStatistics(params) {
    let url = TCHYURL + "/order/bank/queryCostStatistics";
    return myaxios.post(url, params);
  }, //费用统计汇总
  querySummaryCostStatistics(params) {
    let url = TCHYURL + "/order/bank/querySummaryCostStatistics";
    return myaxios.post(url, params);
  }, //费用统计导出
  queryExportCostStatistics(params) {
    let url = TCHYURL + "/order/bank/queryExportCostStatistics";
    return myaxios.post(url, params);
  },
  //司机费用统计
  queryPlatformDriver(params) {
    let url = TCHYURL + "/order/bank/queryPlatformDriver";
    return myaxios.post(url, params);
  },
  //司机费用统计汇总
  querySummaryPlatformDriver(params) {
    let url = TCHYURL + "/order/bank/querySummaryPlatformDriver";
    return myaxios.post(url, params);
  },
  //司机费用统计导出
  queryExportPlatformDriver(params) {
    let url = TCHYURL + "/order/bank/queryExportPlatformDriver";
    return myaxios.post(url, params);
  },
  // 佣金统计列表
  brokerageStatistics(params) {
    let url = TCHYURL + "/order/bank/queryCoreCommissionList";
    return myaxios.get(url, params);
  },
  //佣金统计 导出数据
  queryExportCoreCommission(params) {
    let url = TCHYURL + "/order/bank/queryExportCoreCommission";
    return myaxios.post(url, params);
  },
  // 佣金总和
  querySummaryCoreCommission(params) {
    let url = TCHYURL + "/order/bank/querySummaryCoreCommission";
    return myaxios.post(url, params);
  },
};
export default basicSettingApi;
